package models

import (
	_ "github.com/jinzhu/gorm"
)

type Order struct {
	Id          int
	OrderId     string
	Uid         int //与user.Id关联
	AllPrice    float64
	Phone       string
	Name        string
	Address     string
	Zipcode     string
	PayStatus   int
	PayType     int
	OrderStatus int
	AddTime     int
	OrderItem   []OrderItem `gorm:"foreignkey:OrderId;association_foreignkey:Id"`
}

func (Order) TableName() string {
	return "order"
}
